<template>
  <div class="_wrap">
    <div class="_item" v-for="(item, index) in list" :key="index">
      <div class="text">
        <img v-if="index<=2" :src="getIco(index)" style="width: 30px;" />
        <span v-else>NO.{{ index + 1 }}</span>
      </div>
      <div>{{ item.name }}</div>
      <div><count-to class="val" :start-val="0" :end-val="item.value" :decimals="2" :duration="3600" /><span>%</span></div>
    </div>
  </div>
</template>

<script>
  export default {
    name: 'itemLeft1',
    components: {},
    data() {
      return {
        list: [
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 },
          { name: '某某省', value: 10 }
        ]
      }
    },
    mounted() {
    },
    methods: {
      getIco(index){
        return require(`@/assets/img/top${index + 1}.svg`)
      }
    }
  }
</script>

<style scoped lang="scss">
._wrap {
  display: grid; padding-top: 10px;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: 1fr 1fr; grid-row-gap: 10px;
  align-items: center; justify-items: center;
  ._item {
    text-align: center;
    .text {
      color: #769EBF; text-align: center; height: 30px;
    }
  }
}
</style>
